package org.dromara.business.domain.vo;

import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.business.domain.ShoppingCart;
import org.dromara.common.translation.annotation.Translation;
import org.dromara.common.translation.constant.TransConstant;

import java.io.Serial;
import java.io.Serializable;
import java.math.BigDecimal;


/**
 * 购物车视图对象 shopping_cart
 *
 * @author zlj
 * @date 2024-08-20
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = ShoppingCart.class)
public class ShoppingCartVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 购物车id
     */
    @ExcelProperty(value = "购物车id")
    private Long shoppingCartId;

    /**
     * 添加用户的id
     */
    @ExcelProperty(value = "添加用户的id")
    private Long userId;

    /**
     * 任务id
     */
    @ExcelProperty(value = "任务id")
    private Long goodsId;

    /**
     * 任务数量
     */
    @ExcelProperty(value = "任务数量")
    private Integer goodsQuantity;

    /**
     * 添加购物车时的任务价格
     */
    @ExcelProperty(value = "添加购物车时的任务价格")
    private BigDecimal goodsPrice;

    /**
     * 任务名称
     */
    @ExcelProperty(value = "任务名称")
    private String goodsName;

    /**
     * 任务图片地址
     */
    @ExcelProperty(value = "任务图片地址")
    @Translation(type = TransConstant.OSS_ID_TO_URL)
    private String goodsUrl;

    /**
     * 任务分类
     */
    @ExcelProperty(value = "任务分类")
    private String goodsCategory;

    /**
     * 任务属性JSON [{\"key\":\"颜色\",\"value\":\"颜色\"},{\"key\":\"容量\",\"value\":\"4G\"}]
     */
    @ExcelProperty(value = "任务属性JSON [{\"key\":\"颜色\",\"value\":\"颜色\"},{\"key\":\"容量\",\"value\":\"4G\"}]")
    private String goodsAttr;


}
